Converting Image Data

If required, you can restructure image data for different processing or analysis needs. For example, you may have to convert datasets to 32-bit integers if you plan to perform certain arithmetic operations or Laplacian filtering. You can also find it convenient to convert deep learning training sets to float in order to develop universal models. You should note that transformations do not change the dimensions or coordinates of input images. However, data values may be shifted or scaled.

Right-click the image data you want to convert and then choose Modify and Transform > Convert in the pop-up menu to open the Image Converter panel, shown below.

Image Converter panel

Image Converter panel

Options for converting images

 

Description

Input image

Image

You can select the image data to convert in the Image drop-down menu.

Min and max ranges… Displays the range of the data that will be converted, if filtering is not requested.

Filter values

If selected, values from either side of the data range, which is plotted on the histogram, can be excluded from the output.

Filter min… Indicates the lower threshold value. You can enter a value in the edit box or adjust it with lower limit slider on the histogram.

Filter max… Indicates the upper threshold value. You can enter a value in the edit box or adjust it with upper limit slider on the histogram.

Lower replacement value…Lets you specify the value that will represent all the data below the Filter min value.

Upper replacement value… lets you specify the value that will represent all the data above the Filter max value

Output image

Data type

Lets you select a primitive data type for the output dataset — either unsigned char (8 bits), unsigned short (16 bits), unsigned int (32 bits), or float (32 bits).

Unsigned char (8 bits)… 8 bit code one gray value, each bit has either value 0 or value 1. Consequently, 28 = 256 different gray values are possible, with gray values from 0 to 255 (unsigned).

Unsigned short (16 bits)… 216 = 65,536 different gray values are possible, with gray values from 0 to 65,536.

Unsigned int (32 bits)… More than one million different gray values. Gray values from 0 to 1,048,575.

Float (32 bits)… Effective gray values dynamics 32 bit float.

Preserve calibration by rescaling If checked, the original data calibration will be preserved by transforming the offset and slope values. For example, if you convert an image saved as unsigned short to unsigned char, the intensity values will still range from 0 to 65,000. If unchecked, the offset will be set to 0 and the slope will be set to 1. In this case, intensity values will be within the usual data range of the selected data type. For example, if you convert an image saved as unsigned short to unsigned char, the intensity values will range from 0 to 255.

Normalize

If selected, the data spread will be normalized within the selected Min and Max range values.

Note After selecting an output primitive data type, the Min and Max range fields will display the conversion values. If Normalize is selected, these fields can be edited to delimit the range values within which the data will be spread. If clipping occurs, the minimum or maximum value of the output range or both will be equal respective to the smallest or largest value that can be represented by the selected output data type. Data values below the lower limit or above the upper limit will be clamped.